# _*_ coding: utf-8 _*_
# @Time : 2020/10/18 22:03
# @Author : moran office
# File : 18.py
# Software : PyChram

import requests

# str.encode('raw_unicode_escape').decode()

url = "http://www.571xx.com"

# http://www.571xx.com/list/index17.html
# http://www.571xx.com/list/index1.html
# http://www.571xx.com/list/index21.html

# http://www.571xx.com/js/player/dplayer/dplayer.html?videourl=/play/index144840-0-0.html,https://bobolj.com/20200930/ncY3esx7/index.m3u8
# http://www.571xx.com/js/player/dplayer/dplayer.html?videourl=/play/index152257-0-0.html,https://bobolj.com/20200930/AWtL3a5K/index.m3u8

#response = requests.get(url)
# response.encoding = "ISO-8859-1"
# response.encoding = response.apparent_encoding
#response.encoding= requests.utils.get_encodings_from_content(response.text)[0]

#print(response.content)

u = 'http://www.571xx.com/js/player/dplayer/dplayer.html?videourl=/play/index152257-0-0.html,https://bobolj.com/20200930/AWtL3a5K/index.m3u8'
try:
    img = requests.get(u)
    f = open('测试', 'wb')
    f.write(img.content)
    f.close()
except:
    print("发生错误")







